﻿using Joy.Erp.BasicArchives.Core;
using Joy.Erp.BasicArchives.ItemMasters;

namespace Joy.Erp.BasicArchives.Production
{
    public class PlanOrderConsts
    {
        /// <summary>
        /// 单据类型字段是否必填
        /// </summary>
        public static bool OrderTypeIdRequired { get; set; } = true;

        /// <summary>
        /// 单据类型字段是否必填
        /// </summary>
        public static bool ItemMasterIdRequired { get; set; } = true;

        /// <summary>
        /// 料品编号字段是否必填
        /// </summary>
        public static bool ItemCodeRequired { get; set; } = ArchiveAggregateRootConsts.CodeRequired;

        /// <summary>
        /// 料品编号字段长度
        /// </summary>
        public static int ItemCodeMaxLength { get; set; } = ArchiveAggregateRootConsts.CodeMaxLength;

        /// <summary>
        /// 料品名称字段是否必填
        /// </summary>
        public static bool ItemNameRequired { get; set; } = ItemMasterConsts.NameRequired;

        /// <summary>
        /// 料品名称字段长度
        /// </summary>
        public static int ItemNameMaxLength { get; set; } = ItemMasterConsts.NameMaxLength;

        /// <summary>
        /// 规格型号字段长度
        /// </summary>
        public static int ItemSpecMaxLength { get; set; } = ItemMasterConsts.SpecMaxLength;

        /// <summary>
        /// 计划数量字段数据库类型
        /// </summary>
        public static string QuantityColumnType { get; set; } = "decimal(18,6)";

        /// <summary>
        /// 释放数量字段数据库类型
        /// </summary>
        public static string ReleaseQuantityColumnType { get; set; } = "decimal(18,6)";

        /// <summary>
        /// 备注字段长度
        /// </summary>
        public static int MarkMaxLength { get; set; } = 2000;
    }
}
